package com.west.xu.jdbc.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.west.xu.jdbc.annotation.BeanFieldToDB;

import java.io.Serializable;

@TableName(value = "t_user")
public class User implements Serializable {
    public final static String TABLE_NAME = "t_user";

    @TableId(type = IdType.AUTO)
    @BeanFieldToDB(insertField = false, updateField = false)
    private Long id;
    @TableField(value = "Name")
    @BeanFieldToDB(insertField = true, updateField = false)
    private String name;
    @TableField(value = "UserId")
    @BeanFieldToDB(insertField = true, updateField = false)
    private String userId;
    @TableField(value = "Age")
    @BeanFieldToDB(insertField = true, updateField = false)
    private Integer age;
    @TableField(value = "Sex")
    @BeanFieldToDB(insertField = true, updateField = false)
    private Integer sex;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }
}
